<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<c:forEach var="childNode" items="${requestScope.parentNode.children}">
    <li <c:if test="${childNode.checked}">class="active open"</c:if>>
        <c:if test="${not empty childNode.children}">
            <a href="javascript:void(0);" class="dropdown-toggle">
                <i class="menu-icon ${childNode.icon}"></i>
                <span class="menu-text"> ${childNode.name} </span>
                <b class="arrow fa fa-angle-down"></b>
            </a>
        </c:if>
        <c:if test="${empty childNode.children}">
            <a href="${contextPath}${childNode.url}">
                <i class="menu-icon ${childNode.icon}"></i>
                <span class="menu-text"> ${childNode.name} </span>
            </a>
        </c:if>

        <b class="arrow"></b>

        <c:if test="${not empty childNode.children}">
            <ul class="submenu">
                <c:set var="parentNode" value="${childNode}" scope="request"/>
                <c:import url="/WEB-INF/common/back/treeNode.jsp"/>
            </ul>
        </c:if>
    </li>
</c:forEach>
